package net.myjung.content.impl;

import java.util.List;
import java.util.Map;

import net.myjung.content.CttException;
import net.myjung.content.CttText;
import net.myjung.content.ICttDao;
import net.myjung.dao.AbstractDaoHibernate;
import net.myjung.model.Conds;

public class CttDao extends AbstractDaoHibernate implements ICttDao {

	// Text scope begin
	public CttText getText(String id, Map<String,Object> options) throws CttException {
		try {
			return (CttText) get(CttText.class, id, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
	}
	public CttText setText(String user, CttText obj, Map<String,Object> options) throws CttException {
		try {
			set(user, obj, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
		return obj;
	}
	public CttText createText(String user, CttText obj, Map<String,Object> options) throws CttException {
		try {
			create(user, obj, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
		return obj;
	}
	public CttText updateText(String user, CttText obj, Map<String,Object> options) throws CttException {
		try {
			update(user, obj, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
		return obj;
	}
	public CttText deleteText(String id, Map<String,Object> options) throws CttException {
		try {
			return (CttText) delete(CttText.class, id, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
	}
	public List<CttText> getTextList(Conds conds, Map<String,Object> options) throws CttException {
		try {
			return getList(CttText.class, conds, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
	}
	public long getTextSize(Conds conds, Map<String,Object> options) throws CttException {
		try {
			return getSize(CttText.class, conds, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
	}
	public void deleteTextList(Conds conds, Map<String,Object> options) throws CttException {
		try {
			deleteList(CttText.class, conds, options);
		} catch (Exception e) {
			throw new CttException(e);
		}
	}
	// Text scope end

}